package com.ambow.service.impl;

import com.ambow.dao.UserDao;
import com.ambow.dao.impl.UserDaoImpl;
import com.ambow.entity.User;
import com.ambow.service.UserService;
import com.ambow.utils.PageResults;

public class UserServiceImpl implements UserService{
	UserDao dao = new UserDaoImpl();
	@Override
	public User login(String hql, String[] param) {
		return this.dao.login(hql,param);
	}
	@Override
	public boolean add(User user) {
		return this.dao.add(user);
	}
	@Override
	public User queryById(Class  c, int id) {
		return this.dao.queryById(c,id);
	}
	@Override
	public boolean update(User user) {
		return this.dao.update(user);
	}
	@Override
	public PageResults<User> getPageByFetchedHql(String hql, String countHql, Integer pageNo, Integer pageSize) {
		return this.dao.getPageByFetchedHql(hql,countHql,pageNo,pageSize);
	}

}
